package daniel.suen.physics2d.shape;

import java.beans.PropertyChangeSupport;


/**
 * 代表一个可以运动的对象
 * @author daniel.suen
 *
 */
public class Obj {
	/** property change 支持 */
	private PropertyChangeSupport support = new PropertyChangeSupport(this);
	
	/** x方向增量 */
	private double xInc;
	
	/** y方向增量 */
	private double yInc;
	
	private Shape shape;

	//setter and getter 
	public double getXInc() {
		return xInc;
	}

	public void setXInc(double inc) {
		double oldVal = this.xInc;
		xInc = inc;
		support.firePropertyChange("xInc", oldVal, inc);
	}

	public double getYInc() {
		return yInc;
	}

	public void setYInc(double inc) {
		double oldVal = this.yInc;
		yInc = inc;
		support.firePropertyChange("yInc", oldVal, inc);
	}

	public Shape getShape() {
		return shape;
	}

	public void setShape(Shape shape) {
		this.shape = shape;
	}
	
	
}
